package com.school.appleforgetbackend.service.mock;

import com.school.appleforgetbackend.service.mock.MockService;
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
import org.springframework.stereotype.Service;

@Service // 默认注入的真实实现
@ConditionalOnProperty(prefix = "mock.service", name = "user", havingValue = "false")
public class RealUserService implements MockService {
    @Override
    public String getMockUser(Long userId) {
        // 真实的业务逻辑，例如查询数据库
        return "Real User Name for ID: " + userId;
    }
}
